<script>
import detailCommon from "@/api/ppm/detailCommon.js";
import ppmForm from "@/crm3.0part7-ppm/core/ppmForm.vue";
import conmondt from "@/mixins/order/conmondt.js";

export default {
  name: "ipran10461077",
  mixins: [ppmForm, conmondt],

  created() {
    //明细回显回调函数注册，名称必须固定 add wuyx
    window.initPageOfferDetails = this.initPageOfferDetails;
  },
  mounted() {},

  methods: {
    /**
     * 明细回显回调
     */
    initPageOfferDetails(data) {
      console.log("IPRAN_312_订单送审前");
      console.log("data", data);
      console.log("formData", this.formData);
      this.init(); //初始化方法
      this.contractNumType(this.formData["10461503-142002138"].value); //合同编号类型
      this.yunProvider(this.formData["10461504-142002430"].value); //业务场景
      this.resourcePool(this.formData["10461504-142002269"].value); //资源池类型
      this.IDC(); //是否IDC机房专线
      this.businessType(); // 业务类型
      this.cloudProvider(this.formData["10461504-142002912"].value); //云服务提供商
      this.monthCycle(); //收费周期
      this.feeShow(data);
      this.oneFree(this.formData["10461509-141000009"].value);//一次性费是否免费

    },

    init() {
      //电路标签为普通电路
      if (this.formData["10461509-142002190"].value == "13241001") {
        // this.formData["10461509-142002190"].isshow = false; //电路标签
        this.formData["10461509-142002191"].isshow = false; //电路标签文号
      }
    },

    //合同编号类型   add
    contractNumType(val) {
      //合同是否为测试合同不为是
      if (val != "142002138004") {
        this.formData["10461504-142002124"].isshow = false; //是否为测试电路 隐藏
      }
    },

    //业务场景   add
    yunProvider(val) {
      //云网融合型
      if (val == "227900002") {
        if (
          //阿里云、腾讯云、华为云、微软云、AWS、上海自有云（CLSN）、百度云、UCloud
          this.formData["10461504-142002912"].value == "22113552602" ||
          this.formData["10461504-142002912"].value == "22113552603" ||
          this.formData["10461504-142002912"].value == "22113552604" ||
          this.formData["10461504-142002912"].value == "22113552605" ||
          this.formData["10461504-142002912"].value == "22113552606" ||
          this.formData["10461504-142002912"].value == "22113552607" ||
          this.formData["10461504-142002912"].value == "22113552608" ||
          this.formData["10461504-142002912"].value == "22113552609"
        ) {
          this.formData["10461504-142002269"].isshow = false; //资源池类型 隐藏
        }
        //非普通组网时隐藏
        this.formData["10461508-100013021"].isshow = false; //乙端装机地址 隐藏
        this.formData["10461508-100012972"].isshow = false; //乙端用户名称 隐藏
        this.formData["10461507-142002911"].isshow = false; //甲端 是否需要U设备
        this.SetRequired({
          attrName: "是否需要U设备",
          formkey: "10461507-142002911",
          reqName: "empty",
          reqStatus: false,
        }); //甲端 是否需要U设备 非必填
        this.formData["10461508-142002911"].isshow = false; //乙端 是否需要U设备
        this.SetRequired({
          attrName: "是否需要U设备",
          formkey: "10461508-142002911",
          reqName: "empty",
          reqStatus: false,
        }); //乙端 是否需要U设备 非必填
      } else {
        //普通组网
        this.formData["10461504-142002912"].isshow = false; //云服务提供商 隐藏
        this.formData["10461504-142001052"].isshow = false; //云资源池站点 隐藏
        this.formData["10461504-142001053"].isshow = false; //CTYUN账号 隐藏
        this.formData["10461504-142002269"].isshow = false; //资源池类型 隐藏
        this.formData["10461504-142002011"].isshow = false; //本端VPC ID 隐藏
        this.formData["10461504-142002152"].isshow = false; //本端VPC ID网段/掩码  隐藏
        this.formData["10461504-142002013"].isshow = false; //客户侧互联地址/掩码 隐藏
        this.formData["10461504-142002014"].isshow = false; //云侧互联地址/掩码 隐藏
        this.formData["10461504-100011674"].isshow = false; //客户侧网段/掩码 隐藏
        this.formData["10461507-142002911"].isshow = true; //甲端 是否需要U设备
        this.SetRequired({
          attrName: "是否需要U设备",
          formkey: "10461507-142002911",
          reqName: "empty",
          reqStatus: true,
        }); //甲端 是否需要U设备 必填
        this.formData["10461508-142002911"].isshow = true; //乙端 是否需要U设备
        this.SetRequired({
          attrName: "是否需要U设备",
          formkey: "10461508-142002911",
          reqName: "empty",
          reqStatus: true,
        }); //乙端 是否需要U设备 必填
      }
    },

    //资源池类型   add
    resourcePool(val) {
      //不为专属云时
      if (val != "2019072002") {
        this.formData["10461504-142002189"].isshow = false; //专属云ID 隐藏
        this.formData["10461504-142002183"].isshow = false; //专属云名称 隐藏
      }
    },

    //是否IDC机房专线   add
    IDC() {
      if (this.formData["10461504-100012631"].value == "1") {
        this.formData["10461504-142002498"].isshow = true; //机房专线类型
        this.SetRequired({
          attrName: "机房专线类型",
          formkey: "10461504-142002498",
          reqName: "empty",
          reqStatus: true,
        }); //机房专线类型 必填
      } else {
        this.formData["10461504-142002498"].isshow = false; //机房专线类型 隐藏
        this.SetRequired({
          attrName: "机房专线类型",
          formkey: "10461504-142002498",
          reqName: "empty",
          reqStatus: false,
        }); //机房专线类型 非必填
        this.formData["10461504-142002498"].value = ""; //机房专线类型 清空
      }
      this.comLine();
    },

    //机房专线类型   add
    comLine() {
      this.formData["10461504-142002499"].isshow = false; //甲端机房编码、
      this.formData["10461504-100011034"].isshow = false; //乙端机房编码
      if (this.formData["10461504-142002498"].value == "2468001") {
        this.formData["10461504-142002499"].isshow = true; //甲端机房编码
      } else if (this.formData["10461504-142002498"].value == "2468002") {
        this.formData["10461504-100011034"].isshow = true; //乙端机房编码
      } else if (this.formData["10461504-142002498"].value == "2468003") {
        this.formData["10461504-142002499"].isshow = true; //甲端机房编码
        this.formData["10461504-100011034"].isshow = true; //乙端机房编码
      }
    },

    //MTU数值
    mtuNumber(val) {
      let check = /^[1-9]\d*$/;
      if (check.test(val)) {
        if (val > 9600 || val < 1518) {
          this.$alert("只能填写1518~9600之间的正整数!", "提示", {
            type: "warning",
            confirmButtonText: "关闭",
          });
          this.formData["10461504-141000144"].value = "";
        }
      } else {
        this.$alert("只能填写1518~9600之间的正整数!", "提示", {
          type: "warning",
          confirmButtonText: "关闭",
        });
        this.formData["10461504-141000144"].value = "";
      }
    },

    //IPRAN暂时屏蔽“点到多点”，后端不支撑
    businessType() {
      //点到多点
      if (this.formData["10461504-100001004"].value == "88800130002") {
        this.formData["10461507-142002428"].isshow = true; //甲端是否汇聚主点 展示
        this.SetRequired({
          attrName: "是否汇聚主点",
          formkey: "10461507-142002428",
          reqName: "empty",
          reqStatus: true,
        }); //甲端是否汇聚主点 必填
        this.formData["10461508-142002428"].isshow = true; //乙端是否汇聚主点 展示
        this.SetRequired({
          attrName: "是否汇聚主点",
          formkey: "10461508-142002428",
          reqName: "empty",
          reqStatus: true,
        }); //乙端是否汇聚主点 必填
        this.formData["10461507-142002908"].isshow = true; //汇聚组号
        this.formData["10461508-142002908"].isshow = true;
        this.formData["10461507-142002910"].isshow = true; //汇聚同组电路数
        this.formData["10461508-142002910"].isshow = true;
      } else {
        //点到点
        this.formData["10461507-142002428"].isshow = false; //甲端是否汇聚主点 展示
        this.formData["10461507-142002428"].value = ""; //甲端是否汇聚主点 清空
        this.SetRequired({
          attrName: "是否汇聚主点",
          formkey: "10461507-142002428",
          reqName: "empty",
          reqStatus: false,
        }); //甲端是否汇聚主点 非必填
        this.formData["10461508-142002428"].isshow = false; //乙端是否汇聚主点 展示
        this.formData["10461508-142002428"].value = ""; //乙端是否汇聚主点 清空
        this.SetRequired({
          attrName: "是否汇聚主点",
          formkey: "10461508-142002428",
          reqName: "empty",
          reqStatus: false,
        }); //乙端是否汇聚主点 非必填
        this.formData["10461507-142002908"].isshow = false; //甲端汇聚组号
        this.formData["10461507-142002908"].value = "";
        this.formData["10461508-142002908"].isshow = false; //乙端汇聚组号
        this.formData["10461508-142002908"].value = "";
        this.formData["10461507-142002910"].isshow = false; //甲端汇聚同组电路数
        this.formData["10461507-142002910"].value = "";
        this.formData["10461508-142002910"].isshow = false; //乙端汇聚同组电路数
        this.formData["10461508-142002910"].value = "";
      }
      this.collectA(this.formData["10461507-142002428"].value); //甲端是否汇聚
      this.collectB(this.formData["10461508-142002428"].value); //乙端是否汇聚
    },

    collectA(val) {
      //甲端是否汇聚
      //点到多点
      if (
        val == "2" &&
        this.formData["10461507-142002428"].value == "2" &&
        this.formData["10461504-100001004"].value == "88800130002"
      ) {
        this.$message({
          message: "甲端乙端是否汇聚不可以同时选否",
          showClose: true,
        });
        this.formData["10461507-142002428"].value = "";
      }
      if (val == "1") {
        this.formData["10461507-142002417"].isshow = true;
        this.SetRequired({
          attrName: "汇聚类型",
          formkey: "10461507-142002417",
          reqName: "empty",
          reqStatus: true,
        }); //甲端汇聚类型 必填
        this.formData["10461507-142002416"].isshow = true;
        this.SetRequired({
          attrName: "汇聚VLAN序号/时隙号",
          formkey: "10461507-142002416",
          reqName: "empty",
          reqStatus: true,
        }); //甲端汇聚VLAN序号/时隙号 必填
      } else {
        this.formData["10461507-142002417"].isshow = false;
        this.formData["10461507-142002417"].value = "";
        this.SetRequired({
          attrName: "汇聚类型",
          formkey: "10461507-142002417",
          reqName: "empty",
          reqStatus: false,
        }); // 甲端汇聚类型 非必填
        this.formData["10461507-142002416"].isshow = false;
        this.formData["10461507-142002416"].value = "";
        this.SetRequired({
          attrName: "汇聚VLAN序号/时隙号",
          formkey: "10461507-142002416",
          reqName: "empty",
          reqStatus: false,
        }); //甲端汇聚VLAN序号/时隙号 非必填
      }
      this.collectTypeA(this.formData["10461507-142002417"].value); //甲端汇聚类型
    },

    collectB(val) {
      //乙端是否汇聚
      if (
        val == "2" &&
        this.formData["10461508-142002428"].value == "2" &&
        this.formData["10461504-100001004"].value == "88800130002"
      ) {
        this.$message({
          message: "甲端乙端是否汇聚不可以同时选否",
          showClose: true,
        });
        this.formData["10461508-142002428"].value = "";
        // val=1
      }
      if (val == "1") {
        this.formData["10461508-142002417"].isshow = true;
        this.SetRequired({
          attrName: "汇聚类型",
          formkey: "10461508-142002417",
          reqName: "empty",
          reqStatus: true,
        }); //乙端汇聚类型 必填
        this.formData["10461508-142002416"].isshow = true;
        this.SetRequired({
          attrName: "汇聚VLAN序号/时隙号",
          formkey: "10461508-142002416",
          reqName: "empty",
          reqStatus: true,
        }); //汇聚VLAN序号/时隙号 必填
      } else {
        this.formData["10461508-142002417"].isshow = false;
        this.formData["10461508-142002417"].value = "";
        this.SetRequired({
          attrName: "汇聚类型",
          formkey: "10461508-142002417",
          reqName: "empty",
          reqStatus: false,
        }); //乙端汇聚类型 非必填
        this.formData["10461508-142002416"].isshow = false;
        this.formData["10461508-142002416"].value = "";
        this.SetRequired({
          attrName: "汇聚VLAN序号/时隙号",
          formkey: "10461508-142002416",
          reqName: "empty",
          reqStatus: false,
        }); //乙端汇聚VLAN序号/时隙号 非必填
      }
      this.collectTypeB(this.formData["10461507-142002418"].value); //乙端汇聚类型
    },

    collectTypeA(val) {
      //甲端汇聚类型
      if (val == "80060008002") {
        this.SetRequired({
          attrName: "汇聚参考接入电路代号",
          formkey: "10461507-142002418",
          reqName: "empty",
          reqStatus: true,
        });
      } else {
        this.SetRequired({
          attrName: "汇聚参考接入电路代号",
          formkey: "10461507-142002418",
          reqName: "empty",
          reqStatus: false,
        });
      }
    },

    collectTypeB(val) {
      //乙端汇聚类型
      if (val == "80060008002") {
        this.SetRequired({
          attrName: "汇聚参考接入电路代号",
          formkey: "10461508-142002418",
          reqName: "empty",
          reqStatus: true,
        });
      } else {
        this.SetRequired({
          attrName: "汇聚参考接入电路代号",
          formkey: "10461508-142002418",
          reqName: "empty",
          reqStatus: false,
        });
      }
    },

    //云服务提供商  add
    cloudProvider(val) {
      if (val != "22113552601") {
        //不为天翼云
        this.formData["10461509-142003015"].isshow = true; //多云接入端口月使用费
        this.formData["10461509-100010007"].isshow = true; //多云接入端口收款单位
        this.formData["10461509-100010008"].isshow = true; //多云接入端口委托收款单位
        this.formData["10461509-100011056"].isshow = true; //多云接入端口币种
      } else {
        this.formData["10461509-142003015"].isshow = false; //多云接入端口月使用费
        this.formData["10461509-100010007"].isshow = false; //多云接入端口收款单位
        this.formData["10461509-100010008"].isshow = false; //多云接入端口委托收款单位
        this.formData["10461509-100011056"].isshow = false; //多云接入端口币种
      }
    },

    //收费周期   add
    monthCycle() {
      if (this.formData["10461509-100010009"].value == "80050019028") {
        this.formData["10461509-142001024"].isshow = true; //预收月数
        this.SetRequired({
          attrName: "预收月数",
          formkey: "10461509-142001024",
          reqName: "empty",
          reqStatus: true,
        }); //预收月数 必填
      } else {
        this.formData["10461509-142001024"].isshow = false; //预收月数
        this.SetRequired({
          attrName: "预收月数",
          formkey: "10461509-142001024",
          reqName: "empty",
          reqStatus: false,
        }); //预收月数 非必填
      }
    },

    //费用限制
    numberCheck(val) {
      if (val == "0") {
        this.feeVal = val;
      } else {
        let oldValue = val;
        let newValue = val;
        newValue = newValue.replace(/[^\d.]/g, ""); //清除“数字”和“.”以外的字符
        newValue = newValue.replace(/\.{2,}/g, "."); //只保留第一个. 清除多余的
        newValue = newValue.replace(/^\./g, ""); //必须保证第一个为数字而不是.
        newValue = newValue
          .replace(".", "$#$")
          .replace(/\./g, "")
          .replace("$#$", ".");
        newValue = newValue.replace(/^(\-)*(\d+)\.(\d\d).*$/, "$1$2.$3"); //只能输入两个小数
        if (newValue) {
          let arr = newValue.split(".");
          newValue =
            Number(arr[0]) + (arr[1] === undefined ? "" : "." + arr[1]);
        }
        if (newValue.indexOf(".") < 0 && newValue != "") {
          //以上已经过滤，此处控制的是如果没有小数点，首位不能为类似于 01、02的金额
          newValue = parseFloat(newValue);
        }
        if (oldValue != newValue) {
          this.$alert("请输入正整数或者小数点后两位小数!", "提示", {
            type: "warning",
            confirmButtonText: "关闭",
          });
        }
        this.feeVal = newValue;
      }
    },

    //多云接入端口月使用费
    moreYunRent(val) {
      this.numberCheck(val);
      this.formData["10461509-142003015"].value = this.feeVal;
      this.feeVal = "";
    },

    //甲端调测费
    CommRentA(val) {
      this.numberCheck(val);
      this.formData["10461510-100012523"].value = this.feeVal;
      this.feeVal = "";
    },

    //乙端调测费
    CommRentB(val) {
      this.numberCheck(val);
      this.formData["10461511-100012523"].value = this.feeVal;
      this.feeVal = "";
    },

    //甲端月租费
    monthlyRentA(val) {
      this.numberCheck(val);
      this.formData["10461510-100010742"].value = this.feeVal;
      this.feeVal = "";
    },

    //乙端月租费
    monthlyRentB(val) {
      this.numberCheck(val);
      this.formData["10461511-100010742"].value = this.feeVal;
      this.feeVal = "";
    },

    //国内长途月租费
    domDistanceRent(val) {
      this.numberCheck(val);
      this.formData["10461512-100012567"].value = this.feeVal;
      this.feeVal = "";
    },

    //一次费是否免费   houbin add
    oneFree(val) {
      //免费 公免
      if (val == "11"||val == "10") {
        //调测费默认为0
        this.formData["10461510-100012523"].value = "0";
        this.formData["10461511-100012523"].value = "0";
        this.formData["10461510-100012523"].disabled=true;
        this.formData["10461511-100012523"].disabled=true;
        this.formData["10461509-100012076"].value='1';//一次性费默认为是不可改
        this.formData["10461509-100012076"].disabled=true;
        this.SetRequired({  attrName: "甲端一次性费币种", formkey: "10461510-100010651", reqName: "empty", reqStatus: true, });  //甲端一次性费币种 必填
        this.SetRequired({  attrName: "甲端一次性费币种", formkey: "10461511-100010651", reqName: "empty", reqStatus: true, });  //乙端一次性费币种 必填
      }else{
        this.formData["10461510-100012523"].disabled=false;
        this.formData["10461511-100012523"].disabled=false;
        this.formData["10461509-100012076"].disabled=false;
        this.SetRequired({  attrName: "甲端一次性费币种", formkey: "10461510-100010651", reqName: "empty", reqStatus: false, });   
        this.SetRequired({  attrName: "甲端一次性费币种", formkey: "10461511-100010651", reqName: "empty", reqStatus: false, });   

      }
    },

    /**
     * 设备产商弹窗选中回调方法，回显设备型号、主控板软件版本
     */
    getInputGridValue(obj, flag) {
      let key = obj["key"];
      let optionItem = this.formData[key];
      let itemDevType = detailCommon.getItemByAttrIdRolcd(
        "100013577",
        optionItem.attrRoleCd,
        this.formData
      );
      let itemSoftVersion = detailCommon.getItemByAttrIdRolcd(
        "100012654",
        optionItem.attrRoleCd,
        this.formData
      );
      detailCommon.setItemVal(itemDevType, obj.data.devType);
      detailCommon.setItemVal(itemSoftVersion, obj.data.softVersion);
      if (key.split("-")[1] == "100012972") {
        this.creatCustInfo(obj, flag);
      }
    },

    feeShow(data) {
      let handleStateCd = JSON.parse(
        sessionStorage.getItem("changeRow")
      ).handleStateCd;
      //订单起一次费可改 需求单起送审核前一次费不可改
      if (handleStateCd == "50030002") {
        this.formData["10461504-100000007"].disabled = true; //速率
        this.SetRequired({
          attrName: "",
          formkey: "10461504-100000007",
          reqName: "empty",
          reqStatus: false,
        });
        this.formData["10461507-100013021"].disabled = true; //甲装机地址
        this.SetRequired({
          attrName: "",
          formkey: "10461507-100013021",
          reqName: "empty",
          reqStatus: false,
        });
        this.formData["10461508-100013021"].disabled = true; //乙装机地址
        this.SetRequired({
          attrName: "",
          formkey: "10461508-100013021",
          reqName: "empty",
          reqStatus: false,
        });
        this.formData["10461507-142002911"].disabled = true; //甲是否U设备
        this.SetRequired({
          attrName: "",
          formkey: "10461507-142002911",
          reqName: "empty",
          reqStatus: false,
        });
        this.formData["10461508-142002911"].disabled = true; //乙是否U设备
        this.SetRequired({
          attrName: "",
          formkey: "10461508-142002911",
          reqName: "empty",
          reqStatus: false,
        });
        this.formData["10461504-100001004"].disabled = true; //业务类型
        this.SetRequired({
          attrName: "",
          formkey: "10461504-100001004",
          reqName: "empty",
          reqStatus: false,
        });
        this.formData["10461507-100013204"].disabled = true; //甲端端口类型
        this.SetRequired({
          attrName: "",
          formkey: "10461507-100013204",
          reqName: "empty",
          reqStatus: false,
        });
        this.formData["10461508-100013204"].disabled = true; //乙端端口类型
        this.SetRequired({
          attrName: "",
          formkey: "10461508-100013204",
          reqName: "empty",
          reqStatus: false,
        });
        this.formData["10461509-100012076"].disabled = true; //一次性费是否一口价
        this.SetRequired({
          attrName: "",
          formkey: "10461509-100012076",
          reqName: "empty",
          reqStatus: false,
        });
        this.formData["10461509-100011646"].disabled = true; //是否与首次月租一起支付
        this.SetRequired({
          attrName: "",
          formkey: "10461509-100011646",
          reqName: "empty",
          reqStatus: false,
        });
        this.formData["10461509-141000009"].disabled = true; //一次性费是否免费
        this.SetRequired({
          attrName: "",
          formkey: "10461509-141000009",
          reqName: "empty",
          reqStatus: false,
        });
        this.formData["10461509-100011007"].disabled = true; //一次性费用收费方式
        this.SetRequired({
          attrName: "",
          formkey: "10461509-100011007",
          reqName: "empty",
          reqStatus: false,
        });
        this.formData["10461510-100010651"].disabled = true; //一次性费用币种
        this.SetRequired({
          attrName: "",
          formkey: "10461510-100010651",
          reqName: "empty",
          reqStatus: false,
        });
        this.formData["10461510-100012523"].disabled = true; //调测费
        this.SetRequired({
          attrName: "",
          formkey: "10461510-100012523",
          reqName: "empty",
          reqStatus: false,
        });
        this.formData["10461510-100013081"].disabled = true; //一次性费用收款单位
        this.SetRequired({
          attrName: "",
          formkey: "10461510-100013081",
          reqName: "empty",
          reqStatus: false,
        });
        this.formData["10461510-100013366"].disabled = true; //一次性委托收款单位
        this.SetRequired({
          attrName: "",
          formkey: "10461510-100013366",
          reqName: "empty",
          reqStatus: false,
        });
        this.formData["10461511-100010651"].disabled = true; //一次性费用币种
        this.SetRequired({
          attrName: "",
          formkey: "10461511-100010651",
          reqName: "empty",
          reqStatus: false,
        });
        this.formData["10461511-100012523"].disabled = true; //调测费
        this.SetRequired({
          attrName: "",
          formkey: "10461511-100012523",
          reqName: "empty",
          reqStatus: false,
        });
        this.formData["10461511-100013081"].disabled = true; //一次性费用收款单位
        this.SetRequired({
          attrName: "",
          formkey: "10461511-100013081",
          reqName: "empty",
          reqStatus: false,
        });
        this.formData["10461511-100013366"].disabled = true; //一次性委托收款单位
        this.SetRequired({
          attrName: "",
          formkey: "10461511-100013366",
          reqName: "empty",
          reqStatus: false,
        });
      }
      //正常变更的地址变更不能修改月租费
      let serviceOfferId = JSON.parse(
        sessionStorage.getItem("changeRow")
      ).serviceOfferId;
      if (data.ORDER_DETAIL[0] && data.ORDER_DETAIL[0].CUSTOMER_ORDER[0]) {
        let custOrderType =
          data.ORDER_DETAIL[0].CUSTOMER_ORDER[0].custOrderType;
        if (custOrderType == "50200003" && serviceOfferId == "4041000000") {
          for (let i in this.formData) {
            if (
              this.formData[i].tableName == "ORD_OFFER_INST_FEE_INFO" ||
              this.formData[i].tableName == "ORD_PROD_INST_ACCT_REL" ||
              this.formData[i].tableName == "ORD_OFFER_INST_FEE_ATTR" ||
              this.formData[i].colId == "142001024" ||
              this.formData[i].colId == "100012516" ||
              this.formData[i].colId == "100012632"
            ) {
              //月租费，预收月数 SLA加收比率(%) 返点单位类型
              this.formData[i].disabled = true;
            }
          }
        }
      }
    },
  },
};
</script>
